// pages/order/TransDetail.js
Page({

  /**
   * 页面的初始数据
   */
  data: {

    scrollHeight:1,
    scrollWidth:1,
   
    markers: [{
      iconPath: "/assets/imgs/home-ac.png",
      id: 0,
      latitude: 23.099994,
      longitude: 113.324520,
      width: 25,
      height: 25
    },
    
      {
        iconPath: "/assets/imgs/home-ac.png",
        id: 1,
        latitude: 23.12619,
        longitude: 113.424620,
        width: 25,
        height: 25
      }
    
    ],
    polyline: [{
      points: [{
        longitude: 113.3245211,
        latitude: 23.10229
      }, {
          longitude: 113.3245211,
          latitude: 23.11229
        }, {
          longitude: 113.3246211,
          latitude: 23.11229
        }, {
          longitude: 113.3246211,
          latitude: 23.12229
        }, {
        longitude: 113.424620,
        latitude: 23.12619
      }],
      color: "#0094ed",
      width: 3,
      dottedLine: true
    }],
    // controls: [{
    //   id: 1,
    //   iconPath: '/assets/imgs/home-ac.png',
    //   position: {
    //     left: 0,
    //     top: 300 - 50,
    //     width: 50,
    //     height: 50
    //   },
    //   clickable: true
    // }]
  },

  regionchange(e) {
    console.log(e.type)
  },
  markertap(e) {
    console.log(e.detail.markerId)
  },
  controltap(e) {
    console.log(e.detail.controlId)
  },
  /**
   * 生命周期函数--监听页面加载
   */
  onLoad: function (options) {
    let statusBarHeight = wx.getSystemInfoSync().statusBarHeight
    console.log(wx.getSystemInfoSync().windowHeight)
    this.setData({

      scrollHeight: wx.getSystemInfoSync().windowHeight - 55,
      scrollWidth: wx.getSystemInfoSync().windowWidth,
      
    })
  },

  /**
   * 生命周期函数--监听页面初次渲染完成
   */
  onReady: function () {

  },

  /**
   * 生命周期函数--监听页面显示
   */
  onShow: function () {

  },

  /**
   * 生命周期函数--监听页面隐藏
   */
  onHide: function () {

  },

  /**
   * 生命周期函数--监听页面卸载
   */
  onUnload: function () {

  },

  /**
   * 页面相关事件处理函数--监听用户下拉动作
   */
  onPullDownRefresh: function () {

  },

  /**
   * 页面上拉触底事件的处理函数
   */
  onReachBottom: function () {

  },

  /**
   * 用户点击右上角分享
   */
  onShareAppMessage: function () {

  }
})